package cn.fsw.pethome.org.util;

public class AjaxResult {
    private  Boolean success = true;
    private  String msg = "操作成功";
    private AjaxResult (){

    }
    public static AjaxResult ajaxResult(){
        return new AjaxResult();
    }
    public static AjaxResult error(){
        return ajaxResult().setSuccess(false).setMsg("操作失败");
    }

    public Boolean getSuccess() {
        return success;
    }

    public AjaxResult setSuccess(Boolean success) {
        this.success = success;
        return this;
    }

    public String getMsg() {
        return msg;
    }

    public AjaxResult setMsg(String msg) {
        this.msg = msg;
        return this;
    }
}
